import javax.swing.text.html.HTMLDocument;
import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);

        String str = in.nextLine();

        HashSet<Character> hashSet = new HashSet<>();

        for(int i = 0;i < str.length();i++){
            if(hashSet.add(str.charAt(i)));
        }

        Object[] ch = hashSet.toArray();

        for (int i = 0; i < ch.length; i++) {
            System.out.print(ch[i] + " ");
        }

        Iterator<Character> it = hashSet.iterator();

        while(it.hasNext()){
            System.out.print(it.next());
        }

        for(Character c : hashSet){

        }

        Queue<Integer> queue = new LinkedList<Integer>();
         queue.isEmpty();

         Stack s = new Stack();
         s.pop();

    }
}
class Solution {

    static class TreeNode{
        TreeNode left;
        TreeNode right;
        int val;
    }

    public ArrayList<ArrayList<Integer>> Print (TreeNode pRoot) {
        if (pRoot == null) return new ArrayList();

        ArrayList<ArrayList<Integer>> list = new ArrayList<>();

        Stack<TreeNode> s1 = new Stack<>();
        Stack<TreeNode> s2 = new Stack<>();

        s1.push(pRoot);

        boolean flat = false;
        while (!s1.empty() || !s2.empty()) {
            ArrayList<Integer> arr = new  ArrayList<>();

            if (!flat) {
                int size = s1.size();
                while (size-- != 0) {

                    TreeNode cur = s1.pop();
                    arr.add(cur.val);

                    if (cur.left != null) {
                        s2.push(cur.left);
                    }
                    if (cur.right != null) {
                        s2.push(cur.right);
                    }

                }
                flat = true;
            }

            else {

                int size = s2.size();

                while (size-- != 0) {
                    TreeNode cur = s2.pop();
                    arr.add(cur.val);

                    if (cur.right != null) {
                        s1.push(cur.right);
                    }
                    if (cur.left != null) {
                        s1.push(cur.left);
                    }
                    flat = false;
                }
            }

            list.add(arr);

        }

        return list;
    }
}
//自定义实现反转ArrayList
class ReverseArrayList{

    static void reverse(ArrayList ret){

        int left = 0;
        int right = ret.size() -1;
        while(left < right){
            Object tem = ret.get(left);
            ret.set(left,ret.get(right));
            ret.set(right,tem);
            left++;
            right--;
        }

    }

    public static void main(String[] args) {

        ArrayList<Integer> list = new ArrayList<>();

        list.add(1);
        list.add(2);
        list.add(3);
        list.size();
        ReverseArrayList.reverse(list);

        System.out.println(list);
    }
}

//判断一颗树是不是完成二叉树



class Solution2 {

    static class TreeNode{
        TreeNode left;
        TreeNode right;

        int val;

        public TreeNode(int val){
            this.val = val;
        }
    }
    //解法一：使用堆层序遍历，发现不是度为2的节点，使用flat标记
    //发现flat标记后的节点还有孩子节点返回false，有右孩子没左孩子的
    // 返回false，其他返回true
    public boolean isCompleteTree1 (TreeNode root) {

        if(root.left == null && root.right == null) return true;

        Queue<TreeNode> queue = new LinkedList<>();

        queue.offer(root);

        boolean flat = false;

        while(!queue.isEmpty()){

            TreeNode cur = queue.poll();

            if(cur.left == null && cur.right != null) return false;

            if(flat && cur.left != null) return false;

            if(cur.left == null || cur.right == null){
                flat = true;
            }

            if(cur.left != null){
                queue.offer(cur.left);
            }

            if(cur.right != null){
                queue.offer(cur.right);
            }

        }

        return true;
    }
    //解法二：使用辅助堆，利用可以添加null的特点，将度不为二的节点的左右孩子
    //都加入队列中，当发现空节点时进行标记，如果队列中还存在不为null的节点
    //返回false，其他返回true
    public boolean isCompleteTree2 (TreeNode root) {

        if(root.left == null && root.right == null) return true;

        Queue<TreeNode> queue = new LinkedList<>();

        queue.offer(root);

        boolean flat = false;

        while(!queue.isEmpty()){

            TreeNode cur = queue.poll();

            if(cur == null) {
                flat = true;
                continue;
            }
            if(flat)
                return false;

            queue.offer(cur.left);
            queue.offer(cur.right);
        }

        return true;
    }
    //解法三：使用堆层序遍历，将所有节点的左右孩子都加入队列中
    //然后进行出队列操作，发现存在有不为空的节点返回false
    //其他返回true
    public static boolean isCompleteTree3 (TreeNode root) {

        if(root.left == null && root.right == null) return true;

        Queue<TreeNode> queue = new LinkedList<>();

        TreeNode cur = root;

        queue.offer(root);

        //入队列，找到度不为二节点的孩子节点（null）
        while(cur != null){

            cur = queue.poll();

            if(cur != null) {
                queue.offer(cur.left);
                queue.offer(cur.right);
            }
        }
        //此时如果队列中还存在不为空的节点，说明不是满二叉树
        while(!queue.isEmpty()){

            if(queue.peek() != null){
                return false;
            }
            queue.poll();
        }
        return true;
    }

    public static void main(String[] args) {
        TreeNode node1 = new TreeNode(1);
        TreeNode node2 = new TreeNode(2);
        TreeNode node3 = new TreeNode(3);
        TreeNode node4 = new TreeNode(4);
        TreeNode node5 = new TreeNode(5);
        TreeNode node6 = new TreeNode(6);

        node1.left = node2;
        node1.right = node3;

        node2.left = node4;
        node2.right = node5;
        node3.right = node6;

        System.out.println(Solution2.isCompleteTree3(node1));
    }

}